import sys
sys.path.append('.')
from doctest import DocTestFinder, DocTestRunner

import duetopia.metadata
import duetopia.metadata.iso19115
import duetopia.metadata.iso19139
import duetopia.metadata.fgdc
import duetopia.metadata.rdf

runner = DocTestRunner()
finder = DocTestFinder()
#modules = (bbox.BBox,bbox.index.postgis.Index)
modules = [
	duetopia.metadata,
	duetopia.metadata.iso19115,
	duetopia.metadata.iso19139,
	duetopia.metadata.fgdc,
    duetopia.metadata.rdf,
]

for m in modules:
    for test in finder.find(m): runner.run(test)

print runner.summarize(verbose=True)

